import http from '@http/http'
function severice () {
  let myseverice = {}
  // 获取审核状态
  myseverice._getExamineStatus = () => {
    return new Promise((resolve, reject) => {
      resolve([
        {
          id: 0,
          name: '审核中'
        },
        {
          id: 1,
          name: '通过'
        },
        {
          id: -1,
          name: '驳回'
        }
      ])
    })
  }
  // 获取审核列表
  myseverice._getAuditList = (data) => {
    return http.POST(`./api/instructor/getAuditList`, data)
  }
  // 根据审核表id查询详细
  myseverice._findCommitHistoryInfoById = (id) => {
    return http.GET(`./api/instructor/findCommitHistoryInfoById/${id}`)
  }
  // 审批通过 POST /api/instructor/pass/{id}
  myseverice._passById = (id) => {
    return http.POST(`./api/instructor/pass/${id}`)
  }
  // 驳回
  myseverice._rejectById = (data) => {
    return http.POST(`./api/instructor/reject`, data)
  }
  return myseverice
}
export default severice
